package com.hadwinling.alogriithm.projectforpso.onepso

import breeze.linalg.sum
import breeze.numerics.pow

object Fitness {
  def fitness(pop:Array[Double]):Double = {
    sum(pop.map(x => pow(x,2)))
  }
}
